Arm backend: Wire examples/arm/run.sh for cortex-m55+int8 e2e testing#19073
Conversation
Adds cortex-m55+int8 target support to the public Arm runner scripts so the bundled-IO FVP test flow is reachable from examples/arm/run.sh instead of being inlined in .ci/scripts/test_cortex_m_e2e.sh. backends/arm/scripts/run_fvp.sh now accepts --bundle=<bpte> and, when the target matches cortex-m, launches the Corstone-300 FVP with semihosting enabled and the cortex-m test runner as the loaded ELF, then greps the FVP log for the Test_result: PASS/FAIL line emitted by the bundled-IO runner. examples/arm/run.sh detects cortex-m targets, force-disables --delegate (the cortex-m backend is an operator library, not a delegate), invokes backends/cortex_m/test/build_test_runner.sh for the shared semihosting runner, and delegates the FVP launch to run_fvp.sh. .ci/scripts/test_cortex_m_e2e.sh becomes a thin wrapper over run.sh so CI and user-facing docs exercise the same code path. The redundant build_test_runner.sh invocation in trunk.yml is removed since run.sh now calls it internally. This change was authored with Claude (claude-opus-4-7[1m]).
🔗 Helpful Links🧪 See artifacts and rendered test results at hud.pytorch.org/pr/pytorch/executorch/19073
Note: Links to docs will display an error until the docs builds have been completed. ❌ 1 New Failure, 3 Cancelled Jobs, 5 Unrelated FailuresAs of commit 6a25889 with merge base e4ab34d ( NEW FAILURE - The following job has failed:
CANCELLED JOBS - The following jobs were cancelled. Please retry:
FLAKY - The following jobs failed but were likely due to flakiness present on trunk:
BROKEN TRUNK - The following jobs failed but were present on the merge base:👉 Rebase onto the `viable/strict` branch to avoid these failures
This comment was automatically generated by Dr. CI and updates every 15 minutes. |
This PR needs a
|
|
@claude review |
|
Claude finished @psiddh's task in 3m 20s —— View job Review: Arm backend cortex-m55+int8 e2e wiring
Overall this is a well-structured PR. Consolidating the e2e flow into A few items worth addressing: 1.
Suggestion: either drop 2. Dummy-input file coupling between
Consider having 3. At ... | sed 's/\r$//' | tee ${log_file} || true
echo "[${BASH_SOURCE[0]}] Simulation complete, $?"The 4.
5. FVP model selection uses
Summary: The PR cleanly consolidates the cortex-m e2e flow. Items 1 and 2 are the most actionable — the rest are nits or pre-existing patterns. Nice work reducing |
|
Accepting it to unblock |
|
Looks like there is a merge conflict (--quantize is silently ignored by run.sh seems reasonable feedback from Claude) |
# Conflicts: # .github/workflows/trunk.yml
Drops `--quantize` from .ci/scripts/test_cortex_m_e2e.sh — run.sh has no such flag (only --no_quantize), so it was being silently swallowed; the default behavior is to quantize, so the wrapper just needs to omit it. Moves the dummy-input file creation back into run_fvp.sh so the script is self-contained when given --bundle=. Previously run.sh created fvp_dummy_input.bin next to the .bpte and run_fvp.sh asserted its existence — a cross-script contract enforced only by ordering. With this change run_fvp.sh creates the placeholder itself; future callers of run_fvp.sh --bundle= no longer need to know about the requirement. Adds a cortex-m branch to run.sh's check_setup() so a missing arm-none-eabi-gcc toolchain surfaces immediately rather than deeper in the build_test_runner.sh chain. Adds a comment to run_fvp.sh's FVP-model selection noting that cortex-m55 specifically maps to the SSE-300 FVP because it's the only Cortex-M CPU on Corstone-300 today; cortex-m85 falls through to SSE-320. Removes the now-redundant `backends/cortex_m/test/build_test_runner.sh` step from the reusable cortex-m e2e workflow — run.sh invokes it internally as part of the cortex-m target branch. This change was authored with Claude (claude-opus-4-7[1m]).
|
Failures unrelated. |
Summary
Adds cortex-m55+int8 target support to the public Arm runner scripts so the bundled-IO FVP test flow is reachable from examples/arm/run.sh instead of being inlined in .ci/scripts/test_cortex_m_e2e.sh.
backends/arm/scripts/run_fvp.sh now accepts --bundle= and, when the target matches cortex-m, launches the Corstone-300 FVP with semihosting enabled and the cortex-m test runner as the loaded ELF, then greps the FVP log for the Test_result: PASS/FAIL line emitted by the bundled-IO runner. examples/arm/run.sh detects cortex-m targets, force-disables --delegate (the cortex-m backend is an operator library, not a delegate), invokes backends/cortex_m/test/build_test_runner.sh for the shared semihosting runner, and delegates the FVP launch to run_fvp.sh.
.ci/scripts/test_cortex_m_e2e.sh becomes a thin wrapper over run.sh so CI and user-facing docs exercise the same code path. The redundant build_test_runner.sh invocation in trunk.yml is removed since run.sh now calls it internally.
This change was authored with Claude (claude-opus-4-7[1m]).
Test plan
cc @digantdesai @freddan80 @per @zingo @oscarandersson8218 @mansnils @Sebastian-Larsson @robell